{template 'content', 'header'}
<script type="text/javascript" src="{JS_PATH}cookie.js"></script>
<script type="text/javascript" src="{JS_PATH}dialog.js"></script>
<link href="{CSS_PATH}dialog_simp.css" rel="stylesheet" type="text/css" />
<div class="content">
  <div class="member_login">
  <h1>登录走走网</h1>
<form method="post" action=""  onsubmit="return save_usernamecheck();" id="myform" name="myform">
<input type="hidden" name="forward" id="forward" value="{$forward}">
         <div id="login_email">
          <label for="">账号:</label>
          <input name="username" type="text"  class="text" id="username"/>
         </div>
          <div id="login_pass">
          <label for="">密码:</label>
         <input name="password" type="password"  class="text" id="password" />
         </div>
         <div class="login_options"><input type="checkbox" name="cookietime" value="2592000" id="cookietime" onclick="save_username();" class="checkbox"><p>记住我（下次自动登录）</p>
         <p id="forgetpass"><a href="index.php?m=member&c=index&a=public_forget_password&siteid={$siteid}" class="blue">忘记密码?</a></p>
         </div>
       <div id="login_submit"><input name="dosubmit" class="dosubmit" type="submit" value="提交" /></div>
    </form>
  </div>
   <!--member_login end-->
   <div class="login_fast">
     <h2>用以下帐号直接登录</h2>
       <ul>
        	 {if $setting['sina_akey'] || $setting['sina_skey']}
						<li><a href="javascript:;" onclick="show_login('sina');return false;"><img src="{IMG_PATH}member/logo/sina_login_btn.png" /></a></li>
			{/if}
			{if $setting['qq_appkey'] || $setting['qq_appid']}
						<li><a href="javascript:;" onclick="show_login('qq');return false;"><img src="{IMG_PATH}member/logo/qq_login.gif" /></a></li>
			{/if}
       </ul>
   </div>
</div>
{template 'content', 'footer'}

<script language="JavaScript">
<!--
	function save_username() {
		if($('#cookietime').attr('checked')==true) {
			var username = $('#username').val();
			setcookie('username', username, 3);
		} else {
			delcookie('username');
		}
	}
	var username = getcookie('username');
	if(username != '' && username != null) {
		$('#username').val(username);
		$('#cookietime').attr('checked',true);
	}

	function show_login(site) {
		if(site == 'sina') {
			art.dialog({lock:false,title:'{L('sina_login')}',id:'protocoliframe', iframe:'index.php?m=member&c=index&a=public_sina_login',width:'500',height:'310',yesText:'{L('close')}'}, function(){
			});
		}else if(site =='qq'){
			art.dialog({lock:false,title:'QQ登陆',id:'qq_login', iframe:'index.php?m=member&c=index&a=public_qq_login2',width:'700',height:'520',yesText:'{L('close')}'}, function(){
			});
		}
	}
	function save_usernamecheck()
{
	
	if($('#username').val()=='')
	{
		alert('请输入账号');
		$('#username').focus();
		return false;
	}
	if($('#password').val()=='')
	{
		alert('请输入密码');
		$('#password').focus();
		return false;
	}
	return true;
}
//-->
</script>
